package com.waji.activity;

import android.content.Context;
import android.content.Intent;

import com.waji.http.SendLocation;
import com.waji.local.NextDay;
import com.waji.local.SharedPrefer;
import com.waji.service.LocationService;
import com.waji.service.StateService;
import com.waji.service.PhotoService;

public class InitOther {

	public void init(Context context,String info) {
		NextDay day = new NextDay();
		day.CreatFile(context);
	 
		SendLocation ss=new SendLocation();
    	ss.saveLocation(context); 
		Intent state = new Intent(context, StateService.class);
		context.startService(state);
		Intent photo = new Intent(context, PhotoService.class);
		context.startService(photo);
		Intent location = new Intent(context, LocationService.class);
		context.startService(location);
		
		  try {
				SharedPrefer.SaveUsername(context, info);
				SharedPrefer.SaveService(context, "stop");
			} catch (Exception e) {
				 e.printStackTrace();
			}
	}
}
